package com.vedeng.study.model;

import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * blog1
 * @author 
 */
@Data
public class Blog1 implements Serializable {
    /**
     * 表自增id
     */
    private Integer id;

    /**
     * 博客id
     */
    private Long blogid;

    /**
     * 博客标题
     */
    private String blogtitle;

    /**
     * 博客作者id
     */
    private String blogauthor;

    /**
     * 删除标识,0:未删除;1:删除
     */
    private String isdel;

    /**
     * 创建者
     */
    private String creator;

    /**
     * 修改者
     */
    private String updater;

    /**
     * 创建时间
     */
    private Date addtime;

    /**
     * 修改时间
     */
    private Date modtime;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Blog1 other = (Blog1) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getBlogid() == null ? other.getBlogid() == null : this.getBlogid().equals(other.getBlogid()))
            && (this.getBlogtitle() == null ? other.getBlogtitle() == null : this.getBlogtitle().equals(other.getBlogtitle()))
            && (this.getBlogauthor() == null ? other.getBlogauthor() == null : this.getBlogauthor().equals(other.getBlogauthor()))
            && (this.getIsdel() == null ? other.getIsdel() == null : this.getIsdel().equals(other.getIsdel()))
            && (this.getCreator() == null ? other.getCreator() == null : this.getCreator().equals(other.getCreator()))
            && (this.getUpdater() == null ? other.getUpdater() == null : this.getUpdater().equals(other.getUpdater()))
            && (this.getAddtime() == null ? other.getAddtime() == null : this.getAddtime().equals(other.getAddtime()))
            && (this.getModtime() == null ? other.getModtime() == null : this.getModtime().equals(other.getModtime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getBlogid() == null) ? 0 : getBlogid().hashCode());
        result = prime * result + ((getBlogtitle() == null) ? 0 : getBlogtitle().hashCode());
        result = prime * result + ((getBlogauthor() == null) ? 0 : getBlogauthor().hashCode());
        result = prime * result + ((getIsdel() == null) ? 0 : getIsdel().hashCode());
        result = prime * result + ((getCreator() == null) ? 0 : getCreator().hashCode());
        result = prime * result + ((getUpdater() == null) ? 0 : getUpdater().hashCode());
        result = prime * result + ((getAddtime() == null) ? 0 : getAddtime().hashCode());
        result = prime * result + ((getModtime() == null) ? 0 : getModtime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", blogid=").append(blogid);
        sb.append(", blogtitle=").append(blogtitle);
        sb.append(", blogauthor=").append(blogauthor);
        sb.append(", isdel=").append(isdel);
        sb.append(", creator=").append(creator);
        sb.append(", updater=").append(updater);
        sb.append(", addtime=").append(addtime);
        sb.append(", modtime=").append(modtime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}